namespace Altova.TypeInfo
{
	public class MemberInfo
	{
		private readonly InfoBinderInterface binder;

		private readonly int containingTypeIndex;

		private readonly int dataTypeIndex;

		private readonly string namespaceURI;

		private readonly string localName;

		private readonly MemberFlags flags;

		private readonly int minOccurs;

		private readonly int maxOccurs;

		public string NamespaceURI
		{
			get
			{
				if (namespaceURI != null)
				{
					return namespaceURI;
				}
				return "";
			}
		}

		public string LocalName
		{
			get
			{
				if (localName != null)
				{
					return localName;
				}
				return "";
			}
		}

		public TypeInfo ContainingType
		{
			get
			{
				return binder.Types[containingTypeIndex];
			}
		}

		public TypeInfo DataType
		{
			get
			{
				return binder.Types[dataTypeIndex];
			}
		}

		public MemberFlags Flags
		{
			get
			{
				return flags;
			}
		}

		public int MinOccurs
		{
			get
			{
				return minOccurs;
			}
		}

		public int MaxOccurs
		{
			get
			{
				return maxOccurs;
			}
		}

		public MemberInfo(InfoBinderInterface binder, string namespaceURI, string localName, int containingTypeIndex, int dataTypeIndex, MemberFlags flags, int minOccurs, int maxOccurs)
		{
			this.namespaceURI = namespaceURI;
			this.localName = localName;
			this.binder = binder;
			this.containingTypeIndex = containingTypeIndex;
			this.dataTypeIndex = dataTypeIndex;
			this.flags = flags;
			this.minOccurs = minOccurs;
			this.maxOccurs = maxOccurs;
		}
	}
}
